package edu.sctu.zhuyingzhi.month201505.day20150531.subwayProject;


import java.util.Scanner;

/**
 * Created by user15 on 2015/5/31.
 */
public class MykiMachine {      //余额不足需要充值

    private Scanner input = new Scanner(System.in);     //实例化Scanner对象

    public void myki(SubwayCard subwayCard){

        System.out.println("请输入您要充值的金额：");

        float money = input.nextFloat();                //输入要充值的金额

        subwayCard.Balance =subwayCard.Balance  + money;

        System.out.println("已充值，账户余额为："+subwayCard.Balance);



    }

}
